




class interface:
	def init( self, baudrate, channel ):
		self.callbacks={}
		

		
	def transmit(self, id, data=[] ):
		pass

	def install_callback(self, id, callbackfunction, objdata=None):
		if id in self.listener:
			self.callbacks[id].append( (callbackfunction , objdata ) )
		else:
			self.callbacks[id]=[ (callbackfunction,objdata) ]


	def mythread(self):
		while True:
			id,data=receive()
			if id in self.callbacks
				for callback in self.callbacks[id]:
					callback[0]( id,data, callback[1] )
